<?php

/** 
 * @author Andre Reis
 * @copyright 2010
 */

//===============================================================
//
//======================== CLASS Box ============================
//
//  This class create box content.
//
//===============================================================
Class Box {
    
//===============================================================
//
//======================== GLOBAL VARIABLES =====================
//
//===============================================================

    private $_title_str;
    private $_type_str;
    private $_author_str;
    private $_description_str;
    private $_id_num;
      
    
    //===========================================================
    //
    //======================== FUNCTIONS ========================
    //
    //===========================================================
    
    /********************************
    *
    *     $ Box - Constructor 
    *
    *********************************/
    function Box()
    {
        $this->_title_str       = "?";
        $this->_type_str        = "?";
        $this->_author_str      = "?";
        $this->_description_str = "?";
        $this->_id_num          = -1;
        
    }//Box 
    
    /********************************
    *
    *          $ setTitle 
    *
    *********************************/
    function setTitle( $title_str )
    {
        $this->_title_str = $title_str;
        
    }//setTitle
    
    /********************************
    *
    *          $ setAuthor 
    *
    *********************************/
    function setAuthor( $author_str )
    {
        $this->_author_str = $author_str;
    }//setAuthor
    
    /********************************
    *
    *          $ setType 
    *
    *********************************/
    function setType( $type_str )
    {
        $this->_type_str = $type_str;
    }//setType 
    
    
    
    /********************************
    *
    *      $ setDescription 
    *
    *********************************/
    function setDescription( $description_str )
    {
        $this->_description_str = $description_str;
    }//setDescription 
    
    /********************************
    *
    *      $ setId 
    *
    *********************************/
    function setId( $id_num )
    {
        $this->_id_num = $id_num;
    }//setDescription 
    
    /********************************
    *
    *      $ show 
    *
    *********************************/
    function show()
    {
        echo <<< END
        
        <div class="box_models">
            <a href='download.php?id=$this->_id_num'>        
           
                <div class='box-left'>
           
                    <div class='iconImage'></div>                     
                    <div class='box-title'> $this->_title_str </div>
                    <br/>
                    <br/>
                    <div class='box-author'> Author: $this->_author_str </div>
                    <br/>
                    <div class='box-type'>Type: $this->_type_str </div>
                
                </div> <!-- box-left -->
                
                <div class='box-right'>
                
                    <div class='box-description'>$this->_description_str </div>
                    
    	        </div> <!-- box-right -->        
            </a>
        </div>  <!-- box_models -->
END;
        
    }//show
    
}// Class

?>